package main

import (
	"Demo03/part05-1/MyfunUser"
	"github.com/gin-gonic/gin"
	"net/http"
)

func main() {
	r := gin.Default()
	r.LoadHTMLGlob("part05-1/templates/**/*")
	r.StaticFS("/s", http.Dir("part05-1/static"))

	r.GET("/", MyfunUser.GetIndexHtml)
	r.POST("/submitUser", MyfunUser.SubmitRespose)

	r.POST("/ajaxpost", MyfunUser.AjaxResponse)
	r.Run()
}
